# -*- coding: utf-8 -*-
"""
 @Time    : 2021/2/5 上午9:24
 @Author  : tgy
 
"""
import os
import chardet



def read_dir(path):
    ...
    dir_list = os.listdir(path=path.encode('utf-8'))
    print(dir_list[-1].decode('utf-8'))
    print(chardet.detect(dir_list[-1]))



if __name__ == '__main__':
    ...
    read_dir('/Users/apple/Documents/tmp8/cer')

